<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
        <meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" />
        <meta name="Keywords" content="最新提问|个人用品|办公器材|家居生活|家电数码|汽车天地|品牌印象|个人页面"/>
        <meta name="Description" content="{$question.caption|html_entity_decode=###}|品购网--你需要的商品信息分享及消费自助网站|首页|个人用品|办公器材|家居生活|家电数码|汽车天地|品牌印象|个人页面"/>
        <title>品购网--{$question.caption|html_entity_decode=###}</title>
        <link href="__PUBLIC__/css/hangye.css" rel="stylesheet" type="text/css" />
        <link href="__PUBLIC__/css/comm.css" rel="stylesheet" type="text/css" /> 
		<link href="__PUBLIC__/css/panel.css" rel="stylesheet" type="text/css" />
        <link href="__PUBLIC__/css/question.css" rel="stylesheet" type="text/css" />        
        <link href="__PUBLIC__/css/myshare.css" rel="stylesheet" type="text/css" />
        <script src="__PUBLIC__/js/jquery.js" type="text/javascript"></script>       
        <script src="__PUBLIC__/js/question.js" type="text/javascript"></script>
        <script src="__PUBLIC__/js/myshare.js" type="text/javascript"></script>

        <script type="text/javascript">
            function sharebtn(question_id,share_id,url){
                $.get(url, { question_id: question_id, share_id: share_id },function(data){
                    if(data == 1){
                        alert('分享成功！');
                    }
                    else if(data == 2){
                        alert('请不要重复分享');
                    }
                    else{
                        alert('服务器忙，请重试！');
                    }
                }
            );

            }

            function setBest(share_id,question_id){
                url = "__APP__/Home/Question/best/"
                $.get(url, { question_id: question_id, share_id: share_id },function(data){
                    if(data == 1){
                        alert('设置成功');
                        window.location.reload();
                    }
                    else {
                        alert('设置失败');
                    }
                    
                });
            }
        </script>

    </head>
    <body>
		<div class="containner">
        <include file="Index:header"/>
        <!--导航结束--> 
        <div id="myshare" style="position:absolute;top:0px;margin:auto;z-index:299"></div>
        <div class="body-center">
            <div class="w_tithead"> <strong>您当前的位置是： </strong><a href="__APP__">品购网首页</a><a  href="__APP__/home/Question/">提问内容</a>最新提问</div>
            
            <div class="newquestion_title">最新提问</div>
            <div class="question_div">
                <div class="user">
                    <div>
                        <img src="{$question.user.user_photo|default='__ROOT__/Public/images/user_photo.jpg'}" width="65" height="65">

                    </div>
                    <span>{$question.user.user_name}</span>
                </div>
                <div class="message" id="question_message">
                    <div class="release_time">
                        <span class="left blue"></span><span class="right">发布时间{$question.time_add|date="Y-m-d",###}<eq name="uid" value="$question.userid"><a id="addquestion" href="#">  补充提问</a></eq></span>
                    </div>
                    <div class="content">
			{$question.content|htmlspecialchars_decode=###}
                    </div>
                    <div class="question_add" id="addquestionDiv">
                        <notempty name="addedlist">
                        <div class="title">问题补充：</div><div class="add_question"></div>
                        <volist name="addedlist" id="added">
                            <div class="add_question">{$added.content}</div>
                            <hr width=96% size=1 color=#000000; style="filter:alpha(opacity=100,finishopacity=0,style=1)"></hr>
                        </volist>
                        </notempty>
                    </div>
                    <div id="dd1" style="display:none;">
                        <div class="question_add" id="addquestionDiv"><div class="title">补充提问：</div></div>
                        <div class="addinput" id="addtextarea">
                            <form method="post" action="__APP__/Home/Question/questionAdded">
                                <textarea cols="108" rows="5" id="content" name="content"></textarea>
                                <input type="hidden" value="{$question.id}" name="question_id">
                                <input type="image" align="right" id="submitadd" src="__PUBLIC__/images/submit.gif">
                            </form>
                        </div>
                    </div>

                </div>

            </div>
            <!--我要分享按钮 -->
            <div style="float:right;width:320px;">
                <div ><font color="gray">本次提问已收到</font><span class="yellow">{$count}</span><font color="gray">条分享，提问者已选中</font><span class="yellow">{$best_count}</span><font color="gray">条分享为最佳答案</font></div>
                <!--我要分享按钮 -->
                <img id="sharebtn" class="sharebtn" src="__PUBLIC__/images/ishare.gif" onclick="btn_share_click('__APP__/Home/Share/showMemberShareAjax?id={$question.id}');">

            </div>
             <h3 class="blue" style="clear:both;margin-top:0px;">本提问已有下列回答分享：</h3>

            <!--最佳答案-->           
            <volist name="list" id="myshare">
                <eq name="myshare.is_best_answer" value="1">
                    <div class="answer_div">
                        <div class="user">
                            <div>
                                <img src="{$myshare.user_photo|default='__ROOT__/Public/images/user_photo.jpg'}" width="52" height="52">
                            </div>
                            <span>{$myshare.user_name}</span>
                        </div>
                        <div class="message">
                            <div class="release_time">
                                <span class="left blue"><a href="__APP__/Share/show/id/{$myshare.share_id}">{$myshare.caption}</a></span><span class="right">发布时间：{$myshare.ins_time|date="Y-m-d",###}</a></span>
                            </div>
                            <div class="content">
					{$myshare.content|html_entity_decode=###|strip_tags=###}
                            </div>
                            <div class="smmary">
                                <span><font color="#F00078"><B>^_^</B></font><font color="#46A3FF"><B>被提问者选为最佳答案</B></font></span><span>采纳（<span class="yellow">{$myshare.count_fav}</span>次）</span><span>评分（<span class="yellow">{$myshare.score}</span>分）</span><span>浏览：<span class="yellow">{$myshare.count_view}</span>次</span><span>发表印象：<span class="yellow">{$myshare.brand_count}</span>条</span>
                            </div>
                        </div>
                    </div>
                </eq>
            </volist>
            <volist name="list" id="myshare">
                <eq name="myshare.is_best_answer" value="0">
                    <div class="answer_div">
                        <div class="user">
                            <div>
                                <img src="{$myshare.user_photo|default='__ROOT__/Public/images/user_photo.jpg'}" width="52" height="52">

                            </div>
                            <span>{$myshare.user_name}</span>
                        </div>
                        <div class="message">
                            <div class="release_time">
                                <span class="left blue"><a href="__APP__/Share/show/id/{$myshare.share_id}">{$myshare.caption}</a></span><span class="right">发布时间：{$myshare.ins_time|date="Y-m-d",###}</a></span>
                            </div>
                            <div class="content">
					{$myshare.content|html_entity_decode=###|strip_tags=###}
                            </div>
                            <div class="smmary">

                                <eq name="uid" value="$question.userid">
                                    <span><a href="javascript:;" onclick="setBest('{$myshare.share_id}','{$question.id}');">选它为最佳答案</a></span>
                                </eq>
                                <span>采纳（<span class="yellow">{$myshare.count_fav}</span>次）</span><span>评分（<span class="yellow">{$myshare.score}</span>分）</span><span>浏览：<span class="yellow">{$myshare.count_view}</span>次</span><span>发表印象：<span class="yellow">{$myshare.brand_count}</span>条</span>
                            </div>
                        </div>
                    </div>
                </eq>
            </volist>

            <div id="questionPage" class="paging">
                <!-- <span page="1">首页</span><span>上一页</span><span>1</span><span>2</span><span>3</span><span>下一页</span><span>尾页</span>-->
                {$page}
            </div>

        </div>

    </div>
    <include file="Index:bottom" />
    <!--页尾部分-->
	</div>
    </body>
</html>
